Adding Constraint Handling Rules to Curry

نویسنده

  • Michael Hanus
چکیده

This paper proposes an integration of Constraint Handling Rules (CHR), a rulebased language to specify application-oriented constraint solvers, into the declarative multiparadigm language Curry. This integration provides a convenient way to specify and use flexible constraint systems in applications implemented in Curry. We propose to represent CHR as data objects in Curry programs so that the advantages of Curry (static typing, functional notation) can also be exploited to define CHR. In order to write CHR in a compact way, we define a set of abstractions that hide the concrete CHR data objects. We sketch an implementation of this concept in the Prolog-based Curry implementation PAKCS that compiles CHR data objects into CHR Prolog programs.

منابع مشابه

CHR(Curry): Interpretation and Compilation of Constraint Handling Rules in Curry

Constraint Handling Rules (CHR) is a rule-based language to specify application-oriented constraint solvers. CHR requires a host language that provides the basic constraints used in a CHR program. In this paper, we argue that an integrated functional logic language like Curry is an appropriate host language for CHR since it supports a natural formulation of constraint handling rules and a seaml...

متن کامل

Handling Implication and Universal Quantification Constraints in FLUX

FLUX is a CLP-approach for programming agents that reason about actions under incomplete state knowledge. FLUX is based on the solution to the fundamental frame problem in the fluent calculus. The core is a set of Constraint Handling Rules for the constraints that are used to encode state knowledge. In order to allow for efficient constraint solving, the original expressiveness of state represe...

متن کامل

A new approach to termination analysis of constraint handling rules

We present a new approach to termination analysis of Constraint Handling Rules. The approach, compared to existing approaches, is applicable to a much larger class of CHR programs. A new termination condition is formulated, that instead of a termination argument based on the comparison of sizes of consecutive computation states, verifies conditions imposed on the dynamic process of adding const...

متن کامل

Specialization of Concurrent Guarded Multi-set Transformation Rules

Program transformation and in particular partial evaluation are appealing techniques for declarative programs to improve not only their performance. This paper presents the first step towards developing program transformation techniques for a concurrent constraint programming language where guarded rules rewrite and augment multi-sets of atomic formulae, called Constraint Handling Rules (CHR). ...

متن کامل

Adding Linear Constraints over Real Numbers to Curry

Curry is a multi-paradigm declarative languages that integrates features from functional languages, logic languages, and concurrent programming. In this paper we present an extension of Curry which adds linear constraints over real numbers to the language. The basic kernel of Curry already provides equational constraints and adding linear inequality constraints is a natural task. However, the i...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

متن کامل
عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2006